﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using ConsoleApplication12032011.Loans;
using Contracts;

namespace ConsoleApplication12032011
{
    class Banking
    {
        public static void Main()
        {
            ILoan loanRef = new CarLoan();
            double emiAmt = EmiCalculation(loanRef, 10000.0, 10);

            loanRef = new CarLoan();
            emiAmt = EmiCalculation(loanRef, 10000.0, 10);

        }
        private static double EmiCalculation(ILoan loan, double amt, int yr)
        {
            return loan.GetEmi(10000.0, 5);
        }
    }
}
